<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class AddColTypeToOrdersTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('orders', function (Blueprint $table) {
            $table->string('type')->nullable()->comment('订单类型：common:常规订单;integral:积分订单;group:团购订单;bargain:砍价订单')->after('remark');
        });

        Schema::table('order_item', function (Blueprint $table) {
            $table->string('type')->nullable()->comment('订单类型：common:常规商品;integral:积分商品')->after('status');

        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        //
    }
}
